mod match_test;
mod binder;
mod if_let;
mod while_let;

fn main() {
    let total: f32 = 366.00;
    if total > 200.00 && total < 500.00 {
        println!("打 9 折,{}", total * 0.9)
    } else if total > 500.00 {
        println!("打 8 折,{}", total * 0.8)
    } else {
        println!("无折扣优惠,{}", total)
    }

    let code = "10000";
    let choose = match code {
        "10010" => "联通",
        "10086" => "移动",
        "10000" => "电信",
        _ => "Unknown"
    };
    println!("选择: {}", choose);
}